import Vue from "vue";
import VueRouter from "vue-router";

Vue.use(VueRouter);

export default new VueRouter({
    mode: "hash",
    routes: [{
            path: "/ShouYe",
            name: "shouye",
            component: () => import("../views/ShouYe.vue")
        },
        {
            path: "/HeMaXiaoZen",
            name: "hemaxiaozen",
            component: () => import("../views/HeMaXiaoZen.vue")
        },
        {
            path: "/ChiShenMa",
            name: "chishenma",
            component: () => import("../views/ChiShenMa.vue"),
            children:[
                {
                    path:"/ChiShenMa/JingXuan",
                    name:"jingxuan",
                    component:()=>import("../views/chishenma/JingXuan.vue")
                },
                {
                    path:"/ChiShenMa/CaiPu",
                    name:"caipu",
                    component:()=>import("../views/chishenma/CaiPu.vue")
                },
                {
                    path:"/ChiShenMa/GuanZhu",
                    name:"guanzhu",
                    component:()=>import("../views/chishenma/GuanZhu.vue")
                },
                {
                    path: "/ChiShenMa",
                    redirect: "/ChiShenMa/JingXuan"
                }
            ]
        },
        {
            path: "/Car",
            name: "car",
            component: () => import("../views/Car.vue"),
            children: [
                {
                    path: "/Car/CarCar",
                    name: "carcar",
                    component: () => import("../views/car/CarCar.vue")
                },
                {
                    path: "/Car/CarMai",
                    name: "carmai",
                    component: () => import("../views/car/CarMai.vue")
                },
                {
                    path: "/Car",
                    redirect: "/Car/CarCar"
                }
            ]
        },
        {
            path: "/WoDe",
            name: "wode",
            component: () => import("../views/WoDe.vue")
        },
        {
            path: "/",
            redirect: "/shouye"
        }
    ]
})